//package com.juyu.miliao.api.service;
//
//import javax.annotation.Resource;
//
//import com.juyu.miliao.api.dao.mysql.MakeMoneyDao;
//import com.juyu.miliao.api.domain.MakeMoney;
//import org.springframework.stereotype.Service;
//
//import java.util.List;
//
//@Service
//public class ShareService {
////	@Resource
////	private UserCountDao userCountDao;
////	@Resource
////	private ShareRedisDao shareRedisDao;
////	@Resource
////	private UserWalletDao  userWalletDao;
////	@Resource
////	private SystemMessageUtil systemMessageUtil;
////	@Resource
////	private RedisTemplateService redisTemplateService;
//	@Resource
//	private MakeMoneyDao makeMoneyDao;
//
////	public void addShareSum(Integer userId) {
////		userCountDao.addShareSum(userId);
////	}
//
////	public UserCount getShareAndRewardSumById(Integer userId) {
////		return userCountDao.getShareAndRewardSumById(userId);
////	}
//
////	@Transactional(rollbackFor = Exception.class)
////	public void inputShare(long shareUserId, Integer inputUserId) {
////		if(shareUserId == inputUserId)
////			throw new WrongErrorShare("用户不能输入自己的邀请码");
////		int count = userCountDao.findUserCountByUserId(shareUserId);
////		if(count!=1)
////			throw new WrongErrorShare("邀请码错误");
////		if(shareRedisDao.isMember(inputUserId))
////			throw new WrongErrorShareUserId("该用户已输入过邀请码");
////		shareRedisDao.addShareUser(inputUserId);
////		userCountDao.addRewardSum(shareUserId);
////		userCountDao.addShareSum(shareUserId);
////		UserWallet userWallet = new UserWallet();
////		userWallet.setUserId(shareUserId);
////		userWallet.setDeposit(20);
////		userWalletDao.reviseDeposit(userWallet);
////		//用户统计v值(6.19-土豪值只从充值和获取金币处计算)
////		userCountDao.addVGradeSum(shareUserId, 30);
////		//排行榜统计(6.19-土豪值只从充值和获取金币处计算)
////		redisTemplateService.setVUserSort(shareUserId, 30);
////		systemMessageUtil.shareUser(shareUserId);
////	}
//
//}
